package com.webrtc.demo.util

import com.webrtc.demo.model.SinglingResponse
import retrofit2.http.Field
import retrofit2.http.FormUrlEncoded
import retrofit2.http.POST
import retrofit2.http.Query

interface ApiService {

    @FormUrlEncoded
    @POST("chat/send.xdo")
    suspend fun sendSingling(
        @Field("fromUid") fromUid: String,
        @Field("toUid") toUid: String,
        @Field("msg") msg: String
    ): SinglingResponse


    @POST("chat/list.xdo")
    suspend fun listSingling(
        @Query("fromUid") fromUid: String,
        @Query("toUid") toUid: String
    ): SinglingResponse

    @POST("chat/mark.xdo")
    suspend fun markSingling(@Query("idList") idList: String): SinglingResponse
}